package com.yh.common.constant;

import lombok.Getter;


/**
 * 检测枚举
 */
@Getter
public enum CheckEnums {
	CHECKED(1, "已检测"),
	UNCHECKED(0, "未检测");


	private Integer code;
	private String message;

	CheckEnums(Integer code, String message) {
		this.code = code;
		this.message = message;
	}
	
	public static CheckEnums stateOf(int index) {
		for (CheckEnums state : values()) {
			if (state.getCode() == index) {
				return state;
			}
		}
		return null;
	}
}
